import request from '@/utils/request'

export const prefix = 'flowable';

// 查询流程分类列表
export function listCategory(page,data) {
  return request({
    url: `/${prefix}/category/list`,
    method: 'post',
    params: page,
    data: data
  })
}

// 查询流程类别管理列表
export function listAllCategory() {
  return request({
    url: `/${prefix}/category/list/all`,
    method: 'get'
  })
}

// 查询流程分类详细
export function getCategory(data) {
  return request({
    url: `/${prefix}/category/detail`,
    method: 'post',
    data: data
  })
}

// 新增流程分类
export function addCategory(data) {
  return request({
    url: `/${prefix}/category/add`,
    method: 'post',
    data: data
  })
}

// 修改流程分类
export function updateCategory(data) {
  return request({
    url: `/${prefix}/category/edit`,
    method: 'post',
    data: data
  })
}

// 删除流程分类
export function delCategory(data) {
  return request({
    url: `/${prefix}/category/remove`,
    method: 'post',
    data: data
  })
}
